<?php
	echo '<h5 style="color: red; margin: 6px 0; font-weight: normal;"></h5>';
	echo $this->Form->create('Storey',array('action'=>'edit'));
	echo $this->Form->input('Storey.type', array('label'=>'Tên lầu'));
	echo '<div class="row">';
		echo $this->Form->submit('Save',array('div' => false));
		echo $this->Form->input('Reset',array('type'=>'reset','label'=>false,'div' => false));
	echo '</div>';
	echo $this->Form->end();
?>
<script type="text/javascript" charset="utf-8">
	jQuery(document).ready(function($) {
		$("form").submit(function(event) {
			var str = $("#StoreyType").val().trim();
			if(str == ''){
				event.preventDefault();
				$("h5").html('Tên lầu không được rỗng !');
			}
		});
	})
</script>